<template>
  <div id="app">
    
	
	<router-view/>
	
   
  </div>
</template>
<script>
	//有没有登录
	//登录：进到首页
	//未登录：进到登录页；
		
	export default{
		mounted(){
			if(sessionStorage.getItem("username")){//登录过
				//
				this.$router.push("/homepage")
			}else{
				this.$router.push("/login")
			}
		}
	}
</script>

<style lang="less">
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
}

.home {
 
  a {
    font-weight: bold;
    color: #2c3e50;
	display: block;

    &.link-active {
      color: #42b983;
	  background: red;
    }
  }
}


</style>
